package reflect;

import reflect.annotation.AutoRunClass;

@AutoRunClass
public class Student {
    private String name = "张三";
    private int age = 18;

    private char gender = '男';

    public Student() {
    }

    public Student(String name, int age , char gender) {
        this.name = name;
        this.age = age;
        this.gender = gender;
    }

    public void study() {
        System.out.println("学生"+name+"正在学习...");
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getAge() {
        return age;
    }

    public void setAge(int age) {
        this.age = age;
   }

   public char getGender() {
       return gender;
   }

   public void setGender(char gender) {
       this.gender = gender;
   }

    @Override
    public String toString() {
        return "Student{" +
                "name='" + name + '\'' +
                ", age=" + age +
                ", gender=" + gender +
                '}';
    }
}
